﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using XuanXiang.Infrastructure.Attr;
using XuanXiang.Infrastructure.Dto.Request;
using XuanXiang.Infrastructure.Dto.Request.Goods;
using XuanXiang.Infrastructure.Dto.Response;
using XuanXiang.Infrastructure.Dto.Response.Goods;
using XuanXiang.Infrastructure.EFCore.MySql;

namespace XuanXiang.Service.Interface
{
    [Provider_]
    public interface I_Goods_Service
    {
        /// <summary>
        /// 商品新增
        /// </summary>
        /// <param name="dto"></param>
        /// <returns></returns>
        Api_Result_Dto Add_Goods(GoodsAdd_Dto dto);

        /// <summary>
        /// 商品补货
        /// </summary>
        /// <param name="dto"></param>
        /// <returns></returns>
        Task<Api_Result_Dto> Add_Inventory(AddInventory_dto dto);

        /// <summary>
        /// 商品删除
        /// </summary>
        /// <param name="dto"></param>
        /// <returns></returns>
        Task<Api_Result_Dto> Delete_Goods(Delete_Dto dto);

        /// <summary>
        /// 获取商品列表
        /// </summary>
        /// <param name="dto"></param>
        /// <returns></returns>
        Task<Api_Result_Dto> Get_Goods(Fenye_Dto dto);



        /// <summary>
        /// 获取商品的类别
        /// </summary>
        /// <returns></returns>
        Task<Api_Result_Dto> Get_Goods_Type(Fenye_Dto dto);

        /// <summary>
        /// 获取单个商品
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        Task<Api_Result_Dto> Get_Single_Goods(string? id);

        /// <summary>
        /// 获取单个商品的销售数据
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        Task<Api_Result_Dto> Get_Single_Goods_SalesData(Fenye_Dto dto);

        /// <summary>
        /// 商品上架/下架
        /// </summary>
        /// <param name="dto"></param>
        /// <returns></returns>
        Task<Api_Result_Dto> Update_Shelve(Change_ShelveOrBan_dto dto);
    }
}
